<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../js/1.js">
        // alert('xxxxxxxxxxxxx=========');
    </script>
    <script>
        
    </script>
</head>

<body>
    <a href="javascript:alert('xxxxxxxxxxxxxxxxxxxxxxxxx')">xxxxxxx</a>
    <a href="javascript:;">awdaefwef</a>
    <!-- 可以将js代码写在onclick标签中，但是他们属于结构与行为耦合，不方便维护 -->
    <button onclick="alert('xxxxxxxxx')">xxxxxxx</button>

</body>

</html>